export default {
  data() {
    return {
      total: 0,
      listQuery: {
        page: 1,
        limit: 20,
        importance: undefined,
        title: undefined,
        type: undefined,
        sort: "+id"
      }
    };
  },
  computed: {},

  mounted() { },
  methods: {
    /* 搜索 */
    submitForm(form) {
      this.listQuery.page = 1;
      this.getList();
    },
    /* 重置 */
    resetForm(formName) {
      this.$refs.form.$refs[formName].resetFields();
    },
    // 路由跳转
    jump(name, query) {
      // let tokenAndID = this.$getTokenAndID();
      // let path = `/orderList/${name}?${tokenAndID}`;
      // params.forEach(item => {
      //   path += `&${item.query}=${item.data}`;
      // });
      // let str = `${this.router_url}${path}`;
      // window.open(str);
      this.$router.push({
        name,
        query
      });
    },
    /* 非抽屉式重置 */
    resetOrderForm(formName) {
      this.$refs[formName].resetFields();
    }
  },
  filters: {}
};
